package com.hongxun.design.sqlite.bean;

import android.os.Parcel;
import android.os.Parcelable;

import com.j256.ormlite.field.DatabaseField;

/**
 * Created by admin on 2018/5/3.
 */

public class OldBj implements Parcelable{
    @DatabaseField(id = true, useGetSet = true)
    private String guid;//key
    @DatabaseField(useGetSet = true)
    private String code;
    @DatabaseField(useGetSet = true)
    private String name;
    @DatabaseField(useGetSet = true)
    private String address;
    @DatabaseField(useGetSet = true)
    private String type;
    @DatabaseField(useGetSet = true)
    private String bxCode;
    @DatabaseField(useGetSet = true)
    private String bjCode;
    @DatabaseField(useGetSet = true)
    private String factoryCode;
    @DatabaseField(useGetSet = true,defaultValue = "0")
    private String status;
    @DatabaseField(useGetSet = true)
    private String proId;


    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeString(this.guid);
        dest.writeString(this.code);
        dest.writeString(this.name);
        dest.writeString(this.address);
        dest.writeString(this.type);
        dest.writeString(this.bxCode);
        dest.writeString(this.bjCode);
        dest.writeString(this.factoryCode);
        dest.writeString(this.status);
        dest.writeString(this.proId);
    }

    public OldBj() {
    }

    protected OldBj(Parcel in) {
        this.guid = in.readString();
        this.code = in.readString();
        this.name = in.readString();
        this.address = in.readString();
        this.type = in.readString();
        this.bxCode = in.readString();
        this.bjCode = in.readString();
        this.factoryCode = in.readString();
        this.status = in.readString();
        this.proId = in.readString();
    }

    public static final Creator<OldBj> CREATOR = new Creator<OldBj>() {
        @Override
        public OldBj createFromParcel(Parcel source) {
            return new OldBj(source);
        }

        @Override
        public OldBj[] newArray(int size) {
            return new OldBj[size];
        }
    };

    public String getGuid() {
        return guid;
    }

    public void setGuid(String guid) {
        this.guid = guid;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getAddress() {
        return address;
    }

    public void setAddress(String address) {
        this.address = address;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public String getBxCode() {
        return bxCode;
    }

    public void setBxCode(String bxCode) {
        this.bxCode = bxCode;
    }

    public String getBjCode() {
        return bjCode;
    }

    public void setBjCode(String bjCode) {
        this.bjCode = bjCode;
    }

    public String getFactoryCode() {
        return factoryCode;
    }

    public void setFactoryCode(String factoryCode) {
        this.factoryCode = factoryCode;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public String getProId() {
        return proId;
    }

    public void setProId(String proId) {
        this.proId = proId;
    }
}
